package com.tinysand.advert.support;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.commons.lang.StringUtils;

/**
 * 用户创建请求数据对象
 *
 * Created By TINY
 * Create Time 2020/2/21
 **/
@Data
@AllArgsConstructor
@NoArgsConstructor
public class CreateUserRequest {

    /* 用户名 */
    private String username;

    /**
     * 简单属性数据校验
     *
     * @return 用户名不为空
     */
    public boolean validate() {
        return !StringUtils.isEmpty(username);
    }
}
